<template>
        <div class="super_container">          
                <!-- Home -->

                <!--包含头部和左侧菜单-->

                <myheader></myheader>
                        
                <div id="boxes" class="boxes">
                    <div class="section_container">
                        <div class="container">

                            <div id="contents" style="height:500px;overflow:auto;"></div>
                            <div>
                                <textarea id="msg"></textarea>
                                <a href="javascript:;" onclick="sendMsg()">发送</a>
                            </div>
                                   
                      


                        </div>
                    </div>
                </div>
               
            
                

                <myfooter></myfooter>
            
            
            </div>

      
</template>   
      <script>



        import myheader from './header.vue'
        import myfooter from './footer.vue'
        import Cookies from 'js-cookie'
      
      export default {
        data () {
          return {

            password:'',
            name:'',
            msg: '',
            dataList:[],
            clicked:0,
            upath: '',
          result: '',
          uping:0
          
          }
        },
        components: {
        'myheader':myheader,
        'myfooter':myfooter
        },
        mounted:function(){

            this.common.get_menu();
            
        
      
      },
        methods:{
            changetest(index){
                this.clicked = index;
            },


             sendMsg:function() {
             //设置请求路径
             var ws = new WebSocket("ws://localhost:80/chat");
             var url  = this.base_url+"/chat";                
             // 发送请求:将数据返回到一个回到函数中
             var _this= this;
             // 并且响应成功以后会执行then方法中的回调函数
             this.axios.get(url
                ).then(function(result) {           
                console.log(result);
                
                    });    
                    },
            
            

            
            

        
        
        },
    
        
      }
      
      
      </script>
       
      <style>
      
      
      
      </style>